package nil.ed.simulator.request.client.activity;

import nil.ed.simulator.request.enums.ActivityGroup;

import java.util.Map;

/**
 * 内容.
 * @author lidelin.
 */
public interface IActivity {

    Integer MAX_SORT = Integer.MAX_VALUE;
    Integer MIN_SORT = Integer.MIN_VALUE;

    /**
     * 处理活动.
     * @param attrMap  自定义参数上下文.
     * @return 是否需要继续.
     */
    boolean process(Map<String, Object> attrMap);

    default int getSort() {
        return MAX_SORT;
    }

    default ActivityGroup getGroup() {
        throw new RuntimeException("Group Loss!!");
    }

}
